'use strict';

module.exports = app => {
  const { router, controller } = app;
  const jwt = app.middleware.jwt({secret: app.config.jwt.secret});
  router.get('/members/create', controller.members.create);
  router.post('/members/getToken', controller.members.getToken);
  // router.post('/members/checkInfo', jwt, controller.members.checkInfo);// 一定要注意使用中间件jwt，否则不能获取到app.state.user中的信息
  router.post('/members/checkInfo', controller.members.checkInfo);// 测试在应用层使用中间件 无效

};
